翻訳と辞書
Words near each other
・ True Grit (soundtrack)
・ True Guts
・ True Heart
・ True Heart (song)
・ True Heart Susie
・ True and Living Church of Jesus Christ of Saints of the Last Days
・ True and Untrue
・ True anomaly
・ True arithmetic
・ True as a Turtle
・ True as Steel
・ True as Steel (album)
・ True as Steel (film)
・ True at First Light
・ True at Heart
True BASIC
・ True Beauty
・ True Beauty (album)
・ True Beauty (season 1)
・ True Beauty (season 2)
・ True Beauty (TV series)
・ True believer
・ True Believer (1989 film)
・ True Believer (E-Type song)
・ True Believer (novel)
・ True Believer (Phil Keaggy album)
・ True Believer (Ronnie Milsap album)
・ True Believer (Sawyer Brown album)
・ True Believer (Sparks novel)
・ True Believer (Troy Cassar-Daley album)


Dictionary Lists
翻訳と辞書 辞書検索 [ 開発暫定版 ]
スポンサード リンク

True BASIC : ウィキペディア英語版
True BASIC

True BASIC is a variant of the BASIC programming language descended from Dartmouth BASIC — the original BASIC — invented by college professors John G. Kemeny and Thomas E. Kurtz.
==Background and Features==

When True BASIC appeared on the market in 1985, the BASIC language was widely used on home computers, but with little standardization. Each manufacturer implemented extensions to the language to support features of their hardware. Initially based on Dartmouth BASIC 7 — otherwise known as ANSI BASIC — TrueBASIC implemented a number of new features over GW-BASIC, and allowed the user a redefinable 16-color, 640×480 pixel backdrop for program editing. True BASIC introduced new functions for graphics primitives like plot, plot area, flood, etc. It also was the first to provide a method for saving a portion of the screen and blitting it elsewhere, but had no proper buffering implementation.
Being a structured programming implementation of the language, it dispensed with the need for line numbers and GOTO statements, although these earlier features can still be used. Use of LET for value assignment became optional. It also allowed for descriptive variable names longer than a single letter plus a single digit. For example, the familiar algebraic equation y = mx + b (y = mx + c for the UK) could be expressed as:

let slope = 2
let x = 3
let y_intercept = 4
let y2 = slope
* x + y_intercept
print "y2="; y2
end

The above code segment would yield "y2= 10".
True BASIC provides statements for matrix arithmetic, a feature that had been present in Dartmouth BASIC since early times, but had been dropped in almost all microcomputer versions of BASIC interpreters due to memory limitations. It also supports global and local variables, which permits recursive functions and subroutines to be written.
There are versions of the True BASIC compiler for DOS, Windows, and "classic" Mac OS. There is currently no Mac OS X version of True BASIC, although it may be run in a Windows emulator application. Older computers running Mac OS X can run it through Classic. At one time, versions for Tandy, Amiga and Atari computers were offered, as well as a UNIX command-line compiler.
The designers wanted to make the language hardware-independent, to allow True BASIC source code to run equally well on any version of their compiler. For the most part they succeed in this endeavor. The drawback for users was that direct access to some features of their machines was not available, but this could be remedied with callable functions and subroutines specially written in assembly language.
Using newer versions of True BASIC, some of the older functions are blocked out. An example of the recent code would be more like this:
RANDOMIZE
SET WINDOW 0,20,0,20
SET COLOR 5 !Set the pen and text colour to 5 as true basic has 0-15 colours
PRINT "Welcome To ..." !Print "Welcome To ..." on the user's screen.

DO !Begin the loop
LET x=rnd
*20 !Let the value 'x' equal a random number between '0' and '20'
LET y=rnd
*20 !Let the value 'y' equal a random number between '0' and '20'
Pause .1 !Waits 1/10 of a second
PLOT TEXT, at x, y: "Fabulous Wikipedia!" !Plot 'Fabulous Wikipedia!' at coordinates 'x' and 'y'
LOOP !End the loop

END !End the program
As one can see, even without comments (text following the unquoted exclamation point), True BASIC code can be read rather easily. This simple program plots the text "Welcome To ..." at the top left-hand corner of the screen, and then continues into a never-ending loop plotting "Fabulous Wikipedia!" at random coordinates.
An example of simple animation could be like this:
!Draw the Car
SET WINDOW 0,20,0,20
SET COLOR 5
BOX AREA 2,6,2,3
BOX AREA 9,13,2,3
BOX AREA 16,20,2,3
SET COLOR 249
PLOT LINES :0,5;20,5
FLOOD 10,1
BOX KEEP 0,20,0,5 IN road$
BOX CIRCLE 2,3,5,6
FLOOD 2.5,5.5
BOX CIRCLE 5,6,5,6
FLOOD 5.5,5.5
SET COLOR 35
PLOT LINES :2.5,6;5.5,6
PLOT LINES :5,6;8,6;8,8;6,8;6,10;2,10;2,8;0,8;0,6;3,6
FLOOD 4,8
SET COLOR 248
BOX AREA 4,5,8,9

BOX KEEP 0,8,5,10 IN car$ !Save the car in 'car$'

FOR x=1 TO 20 STEP 1 !Create a 'for' loop
BOX SHOW road$ AT 0,0
BOX SHOW car$ AT x,5
PAUSE .1
CLEAR
NEXT x !End the 'for' loop

END !End the programs

抄文引用元・出典: フリー百科事典『 ウィキペディア(Wikipedia)
ウィキペディアで「True BASIC」の詳細全文を読む



スポンサード リンク
翻訳と辞書 : 翻訳のためのインターネットリソース

Copyright(C) kotoba.ne.jp 1997-2016. All Rights Reserved.